//
// Created by Administrator on 2022/12/26.
//

#include <iostream>
#include <vector>
using namespace std;

// 返回值右置的语法,还是需要auto作为占位符
auto sum(vector<int> arr) ->int ;
auto add1(int a=0,int b=0)->int;

int main()
{
    vector<int> v1{1,2,3,4,5,6,7,8};
    vector<int> v2={23,45,67,89};
    printf("%d\n",sum(v1));
    printf("%d\n",sum(v2));
    int c1 = 'b';  // 隐式类型转换 char-->int
    printf("%d\n",c1);
    printf("%d\n",add1());
}


auto sum(vector<int> arr) ->int
{
    return arr.size();
}

int add1(int a, int b){
    return a+b;
}
